package cn.huiyunche.base.service.interfaces;

import cn.huiyunche.base.service.model.SUserRoute;
import cn.huiyunche.base.service.vo.PageVo;
import cn.huiyunche.base.service.vo.Result;
import cn.huiyunche.base.service.vo.SUserRouteVo;
import cn.huiyunche.tools.basic.exceptions.BusinessException;

import java.util.List;
import java.util.Map;

/**
 * The type S user route service.
 *
 * @FileName: cn.huiyunche.service.base.interfaces
 * @Description: 用户 （分供方）线路
 * @author: Aaron
 * @date: 2016 /12/10 上午11:48
 */
public interface SUserRouteService {

    /**
     * Gets list by user id.
     *
     * @param userId the user id
     * @return the list by user id
     */
    List<SUserRoute> getListByUserId(Long userId);

    /**
     * 分供方－线路维护
     *
     * @param routeVo the route vo
     * @return result result
     * @throws BusinessException the business exception
     */
    Result<Object> modifyRouter(SUserRouteVo routeVo) throws Exception;

    /**
     * 分供方－线路删除
     *
     * @param id the id
     * @return result result
     * @throws BusinessException the business exception
     */
    Result<Object> delRouter(Long id) throws Exception;

    /**
     * 分供方－线路列表
     *
     * @param pageVo  the page vo
     * @param routeVo the route vo
     * @return result result
     * @throws BusinessException the business exception
     */
    Result<Map<String, Object>> list(PageVo pageVo, SUserRouteVo routeVo) throws Exception;

    /**
     * 查询线路
     *
     * @param id the id
     * @return by id
     * @throws BusinessException the business exception
     */
    Result<Object> getById(Long id) throws Exception;


    /**
     * Select by primary s user route.
     *
     * @param routeId the route id
     * @return the s user route
     */
    SUserRoute selectByPrimary(Long routeId);

}
